package com.pand.model.vehicle;

import com.pand.model.BaseObject;

import javax.persistence.*;

/**
 * 
 * @ClassName: Brand 
 * @Description: 品牌信息
 * @author zouyan
 * @date 2016年2月13日 上午10:24:06 
 *
 */
@Entity
@Table(name = "RES_BRAND")
@SequenceGenerator(name = "SeqBrand", sequenceName = "SEQ_BRAND", allocationSize = 1)
public class Brand extends BaseObject{
	
	
	/** 
	 * @Fields serialVersionUID : 
	 */ 
	private static final long serialVersionUID = 1L;
	
	/**
	 * 主键
	 */
	private Long id;
	
	/**
	 * 品牌名字
	 */
	private String brandName;

	/**
	 * 厂商
	 */
	private String manuFactory;
	
	/**
	 * 描述信息
	 */
	private String describe;	
	
	/**
	 * 是否同步
	 */
    private Integer isSynchronous=0;
	
	/**
	 * 品牌类型
	 */
    private String brandType;
	
	/**
	 * 品牌类型名称
	 */
	private String brandTypeName;
	
	/**
	 * 品牌编码
	 */
	private String brandCode;

	@Column(name = "IS_SYNCHRONOUS")
	public Integer getIsSynchronous() {
		return isSynchronous;
	}

	public void setIsSynchronous(Integer isSynchronous) {
		this.isSynchronous = isSynchronous;
	}

	@Id
	@GeneratedValue(generator = "SeqBrand")
	@Column(name = "ID")	
	public Long getId() {
		return id;
	}
	public void setId(Long id) {
		this.id = id;
	}
	
	@Column(name = "BRAND_NAME")
	public String getBrandName() {
		return brandName;
	}
	public void setBrandName(String brandName) {
		this.brandName = brandName;
	}
	
	@Column(name = "MANUFACTURE")
	public String getManuFactory() {
		return manuFactory;
	}
	public void setManuFactory(String manuFactory) {
		this.manuFactory = manuFactory;
	}
	
	@Column(name = "DESCRIBE")
	public String getDescribe() {
		return describe;
	}
	public void setDescribe(String describe) {
		this.describe = describe;
	}
	@Column(name = "BRAND_TYPE")
	public String getBrandType() {
		return brandType;
	}
	public void setBrandType(String brandType) {
		this.brandType = brandType;
//		VNMSCache cache =  VNMSCache.getInstance();
//		SystemCode brand = cache.getBrandType(brandType);
//		this.brandTypeName  = brand.getName();
	}
	@Transient
	public String getBrandTypeName() {
		return brandTypeName;
	}
	public void setBrandTypeName(String brandTypeName) {
		this.brandTypeName = brandTypeName;
	}
	@Column(name = "BRAND_CODE")
	public String getBrandCode() {
		return brandCode;
	}
	public void setBrandCode(String brandCode) {
		this.brandCode = brandCode;
	}
	
}
